﻿using System;
using System.Text;
using Microsoft.Practices.RecipeFramework;
using Microsoft.Practices.RecipeFramework.Library;
using EnvDTE;

namespace EEst.SoftwareFactory.ValueProviders
{
    public class GenAppFilesValueProvider : ValueProvider
    {
        public override bool OnBeginRecipe(object currentValue, out object newValue)
        {
            if (currentValue != null)
            {
                // Do not assign a new value, and return false to flag that 
                // we don't want the current value to be changed.
                newValue = null;
                return false;
            }

            VCPPProjectFileProvider provider = new VCPPProjectFileProvider();
            SetupFiles(provider);
            newValue = provider;

            return true;
        }

        public virtual void SetupFiles(VCPPProjectFileProvider provider)
        {
            provider.SourceFiles = new string[] { };
            provider.HeaderFiles = new string[] { };
        }
    }

    public class VCPPProjectFileProvider
    {
        public string[] SourceFiles
        {
            get { return sources; }
            set { sources = value; }
        } string[] sources;

        public string[] HeaderFiles
        {
            get { return headers; }
            set { headers = value; }
        } string[] headers;

    }

}
